package com.asiainfo.order.config;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

@Data
@Component
@ConfigurationProperties(prefix = "clickhouse.jdbc") //配置批量绑定在nacos下，可以无需@RefreshScope就能实现自动刷新
public class OrderProperties {

    private String url;
    private String password;
    private String username;
    private Integer poolsize;
    private Integer timeout;
    private Flush flush;

    @Data
    static
    class Flush{
        private Integer interval;
        private Integer batchsize;
    }
}
